package leecode.q144;

public class Main {
    public static void main(String[] args) {
        Solution solution = new Solution();
        Solution.TreeNode root = new Solution.TreeNode(1);
        root.left = new Solution.TreeNode(2);
        root.right = new Solution.TreeNode(2);

        root.left.left = new Solution.TreeNode(3);
        root.left.right = new Solution.TreeNode(4);
        root.right.left = new Solution.TreeNode(4);
        root.right.right = new Solution.TreeNode(3);

        root.left.left.left = new Solution.TreeNode(5);
        root.left.left.right = new Solution.TreeNode(6);
        root.right.right.left = new Solution.TreeNode(6);
        root.right.right.right = new Solution.TreeNode(5);

        root.left.right.left = new Solution.TreeNode(7);
        root.left.right.right = new Solution.TreeNode(8);
        root.right.left.left = new Solution.TreeNode(8);
        root.right.left.right = new Solution.TreeNode(7);

        System.out.println(solution.isSymmetric1(root));
    }


}
